<?php
/**
 * 开屏广告
 */

namespace app\api\controller;


use app\api\model\IntervalConfig;
use app\api\model\Region;
use app\common\controller\ApiController;
use think\Exception;
use app\api\model\Adver as AdverModel;

class Adver extends ApiController {

    protected $notNeedToken = ['getlist'];
    protected $notNeedPhone = ['getlist'];

    //开屏广告
    public function getList() {
        try {
            $params = $this->checkParams('');
            if ($params === false) {
                return $this->resErr();
            }
            $data = AdverModel::getList();
            return $this->resData('success', $data);
        } catch (Exception $e) {
            return $this->resErr($e->getMessage(), $e->getCode());
        }
    }

}
